package com.airline.form;

import java.util.ArrayList;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionMapping;
import org.apache.struts.util.LabelValueBean;
import org.apache.struts.validator.ValidatorForm;

import com.airline.beans.Employee;
import com.airline.beans.Flight;
import com.airline.beans.Journey;



public class SearchFlightListForm extends ValidatorForm{
	
	
	
	String error = null;
	
	String ticketNo = null;
	
	public String getTicketNo() {
		return ticketNo;
	}

	public void setTicketNo(String ticketNo) {
		this.ticketNo = ticketNo;
	}

	Flight flight = new Flight();
	
	ArrayList sourceList = new ArrayList();
	ArrayList destList = new ArrayList();
	ArrayList airlinenameList = new ArrayList();
	public String getValue() {
		return value;
	}

	public void setValue(String value) {
		this.value = value;
	}

	Journey[] flightList = null;
	
	String value = null;
	


	

	public Journey[] getFlightList() {
		return flightList;
	}

	public void setFlightList(Journey[] flightList) {
		this.flightList = flightList;
	}

	public Flight getFlight() {
		return flight;
	}

	public void setFlight(Flight flight) {
		this.flight = flight;
	}

	public ArrayList getSourceList() {
		return sourceList;
	}

	public void setSourceList(ArrayList sourceList) {
		this.sourceList = sourceList;
	}

	public ArrayList getDestList() {
		return destList;
	}

	public void setDestList(ArrayList destList) {
		this.destList = destList;
	}

	public ArrayList getStateList() {
		return sourceList;
	}

	public void setStateList(ArrayList stateList) {
		this.sourceList = stateList;
	}

	public SearchFlightListForm() {
		
		
		
		sourceList.add(new LabelValueBean("JFK","JFK"));
		sourceList.add(new LabelValueBean("LAX","LAX"));
		sourceList.add(new LabelValueBean("MSP","MSP"));
		sourceList.add(new LabelValueBean("PDX","PDX"));
		sourceList.add(new LabelValueBean("ORD","ORD"));
		sourceList.add(new LabelValueBean("SEA","SEA"));
		sourceList.add(new LabelValueBean("DEN","DEN"));
		sourceList.add(new LabelValueBean("DCA","DCA"));
		sourceList.add(new LabelValueBean("SFO","SFO"));
		
		
		destList.add(new LabelValueBean("JFK","JFK"));
		destList.add(new LabelValueBean("LAX","LAX"));
		destList.add(new LabelValueBean("MSP","MSP"));
		destList.add(new LabelValueBean("PDX","PDX"));
		destList.add(new LabelValueBean("ORD","ORD"));
		destList.add(new LabelValueBean("SEA","SEA"));
		destList.add(new LabelValueBean("DEN","DEN"));
		destList.add(new LabelValueBean("DCA","DCA"));
		destList.add(new LabelValueBean("SFO","SFO"));
		
		
		airlinenameList.add(new LabelValueBean("DELTA","DELTA"));
		airlinenameList.add(new LabelValueBean("ALASKA","ALASKA"));
		airlinenameList.add(new LabelValueBean("UNITED","UNITED"));
		airlinenameList.add(new LabelValueBean("SOUTHWEST","SOUTHWEST"));
	}

	public ArrayList getAirlinenameList() {
		return airlinenameList;
	}

	public void setAirlinenameList(ArrayList airlinenameList) {
		this.airlinenameList = airlinenameList;
	}

	public String getError() {
		return error;
	}

	public void setError(String error) {
		this.error = error;
	}

	@Override
	public void reset(ActionMapping mapping, HttpServletRequest request) {
		
	}

	

}
